<!DOCTYPE html>
<html>
<head>
    <title>赛事详情</title>
    <meta name="keywords" content="{$site_info.site_seo_keywords|default=''}"/>
    <meta name="description" content="{$site_info.site_seo_description|default=''}">
    <include file="public@head"/>
    <style>
        #article_content img {
            height: auto !important;
            max-width: 100%;
        }

        #article_content {
            word-wrap: break-word;
        }
        .content_td_1 {
            width: 20%;
        }
        .content_td_2 {
            width: 80%;
        }
    </style>
    <hook name="before_head_end"/>
</head>
<body class="body-white">
<include file="public@nav"/>
<div class="container tc-main">
    <div class="row">
        <div class="col-md-9">
            <if condition="empty($contest)">
                <h4>暂时没有比赛</h4>
            <else/>
                <div class="tc-box article-box">
                    <h2>{$contest.title}</h2>
                    <div class="article-infobox">
                        <span>发布时间：{$contest.create_time}</span>
                        <span>

					</span>
                    </div>
                    <hr>
                    <div id="article_content">
                        <div>
                            <img src="{:cmf_get_image_preview_url($contest.picture)}"
                                 id="picture-preview" style="cursor: pointer"/>
                        </div>
                        <div style="margin-top: 30px;">
                            <table class="table table-striped" style="width: 100%;">
                                <tr style="margin-top: 10px;">
                                    <td class="content_td_1">赛事类别</td>
                                    <td class="content_td_2">
                                        <foreach name="categories" index="key" item="vo">
                                            <!--                                        <span style="margin: 2px;">{$vo.name}</span>-->
                                            <a class="label label-default" style="background-color: #a7a2a2;border-radius: 5px;text-decoration:none;" data-toggle="tab">{$vo.name}</a>
                                        </foreach>
                                    </td>
                                </tr>
                                <tr style="margin-top: 10px;">
                                    <td class="content_td_1">报名时间</td>
                                    <td class="content_td_2">{:date('Y-m-d',$contest.apple_start)} - {:date('Y-m-d',$contest.apple_end)}</td>
                                </tr>
                                <tr style="margin-top: 10px;">
                                    <td class="content_td_1">评审时间</td>
                                    <td class="content_td_2">{:date('Y-m-d',$contest.review_start)} - {:date('Y-m-d',$contest.review_end)}</td>
                                </tr>
                                <tr style="margin-top: 10px;">
                                    <td class="content_td_1">内容</td>
                                    <td class="content_td_2">{:htmlspecialchars_decode($contest.desc)}</td>
                                </tr>
                            </table>
                        </div>
                        <div style="margin: auto;text-align: center;">
                            <if condition="$update_str eq 0">
                                <!--                            <button type="submit" class="btn btn-primary js-ajax-submit">保存</button>-->
                                <a class="btn btn-warning" href="{:cmf_url('portal/works/add')}">参加比赛</a>
                                <else/>
                                <a class="btn btn-warning" title="报名时间已结束" disabled>参加比赛</a>
                                <!--                            <button type="submit" class="btn btn-primary js-ajax-submit" title="报名时间已结束" disabled>提交</button>-->
                            </if>
                            <!--                        <a class="btn btn-warning" href="{:cmf_url('portal/works/add')}">参加比赛</a>-->
                        </div>
                    </div>
                </div>
            </if>

        </div>
    </div>
</div>
<include file="public@footer"/>
<include file="public@scripts"/>
<hook name="before_body_end"/>
</body>
</html>